package com.pic.others.service;

import com.pic.common.utils.R;
import com.pic.others.domain.dto.user.LoginFormDTO;
import com.pic.others.domain.dto.user.LoginUserDTO;
import com.pic.others.domain.dto.user.UserDTO;
import com.pic.others.domain.dto.user.UserFormDto;
import com.pic.others.domain.po.User;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author koshi
 * @since 2023-11-24
 */
public interface IUserService extends IService<User> {

    R<String> saveUser(UserFormDto userFormDto);

    boolean addUserByEmail(User user,String code);


    R<LoginUserDTO> queryUser(LoginFormDTO loginFormDTO);

    R<User> updateUser(UserDTO userDTO);

    R<String> updateUserPassword(UserFormDto userFormDto,String checkPassword);

    R<User >updateUserImg(HttpServletRequest request, MultipartFile file);


    R<String> sendCode(String email, Integer number);

    R<User> getUserInfo();
}
